﻿using System;
using Inkubator.Wizard.WebWizard.WizardControl;
using Inkubator.Wizard.WizardGenerator.Generator;
using Inkubator.Wizard.WizardGenerator.Style;

public partial class _Default : System.Web.UI.Page
{

    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            int active = 0;
            int previous = 2;
            this.Session.Add("active", active);
            this.Session.Add("previous", previous);
        }

        string xmlPath = "C://diego//programacion//xml//user2.xml";
        WizardGenerator generator = new WizardGenerator(xmlPath, "");
        
        WizardWeb wizard = generator.obtainWizardControl(this.Session);

        if (!IsPostBack)
        {
            generator.executePreAction();
        }

        WizardStyle style = new WizardStyle(generator.getWizardModel());
        style.applyStyle(wizard);

        this.PlaceHolder1.Controls.Add(wizard);
    }

}
